import java.lang.String;

public class StringArray implements Sort {

	private String[] str;

	public StringArray() {

		this.str = new String[10];

	}

	public StringArray(String[] str) {

		this.str = new String[str.length];
		for (int i = 0; i < str.length; i++) {
			this.str[i] = str[i];
		}

	}

	public String[] getStr() {
		return str;
	}

	public void setStr(String[] str) {
		this.str = str;
	}

	public String toString() {
		for (int i = 0; i < str.length; i++) {
			System.out.println(str[i]);
		}
		return " ";

	}

	public void sort() {

		for (int j = 0; j < str.length; j++) {
			for (int i = j + 1; i < str.length; i++) {
				if (str[i].compareTo(str[j]) < 0) {
					String temp = str[j];
					str[j] = str[i];
					str[i] = temp;
				}
			}

		}

	}
}
